<template>
  <view class="adreementPage">
    <u-navbar
      :title="obj.title"
      :autoBack="true"
      :fixed="true"
      :bgColor="'#fff'"
      :zIndex="1000"
      :height="44"
      :placeholder="true"
      :titleStyle="{
        color: '#333',
        fontSize: '16px',
      }"></u-navbar>
    <!-- <view class="title">{{ obj.title }}</view> -->
    <view class="content" v-html="obj.content"></view>
  </view>
</template>

<script>
import { getcontent } from "@/api/mainapi.js";
import { mapGetters } from "vuex";
export default {
  data() {
    return {
      obj: {},
      id: "",
    };
  },
  computed: mapGetters(["isLogin", "uid", "userInfo"]),
  onLoad(param) {
    this.id = param.id;
  },
  mounted() {
    this.getcont();
  },
  methods: {
    async getcont() {
      const res = await getcontent({
        id: this.id,
      });
      console.log(res);
      if (res.response.statusCode === 200) {
        this.obj = res.data.data;
        console.log(res.data.data, "res.data.data");
      }
    },
  },
};
</script>

<style scoped lang="scss">
.adreementPage {
  height: 100%;
  width: 100%;
  min-height: 100vh;
  background: #f8f8f8;
  .title {
    font-family: SourceHanSansCN, SourceHanSansCN;
    font-weight: 500;
    font-size: 32rpx;
    color: #3e3e3e;
    line-height: 48rpx;
    text-align: center;
    margin-top: 40rpx;
  }
  .content {
    font-family: SourceHanSansCN, SourceHanSansCN;
    font-weight: 400;
    font-size: 28rpx;
    color: #3e3e3e;
    line-height: 48rpx;
    text-align: justify;
    font-style: normal;
    padding: 40rpx;
  }
}
</style>
